/******************************************************************************************************
Copyright (C) 2010 Mestrelab Research S.L. All rights reserved.

This file is part of the MNova scripting toolkit.

Authorized users of MNova Software may use this file freely, but this file is provided AS IS
with NO WARRANTY OF ANY KIND, INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS
FOR A PARTICULAR PURPOSE.
*****************************************************************************************************/
/*globals PeakReporter, Env*/
/*jslint plusplus: true, indent: 4*/

// This function defines US Patent-like peak report.
// To customize report, edit this function or implement another one.
function USPatentPeakReporter() {
	'use strict';
	PeakReporter.call(this);
	this.name = "US Patent";

	// Define font size and font family
	this.font = "<font style=\"font-size: %1pt; font-family: %2; font-style: %3; font-weight: %4; text-decoration: %5; color: %6\">";
	this.nucleusTemplate = "%1";

	// Report header. %1 will be replaced with nucleusString, %2  with frequency, %3 with solvent 
	this.header = " %1 NMR (%3) &delta;:";

	//Peak templates:
	this.peakTemplate = "%1";//%1 - delta

	// Assignments template. %1 - atom number
	this.assignmentsTemplate = "%1";

	this.deltaPrecision = 1; // delta precision
	this.pSeparator = ", "; // peak separator 
	this.start = this.font;
	this.end = ".</font>";
}

USPatentPeakReporter.prototype = new PeakReporter();
USPatentPeakReporter.prototype.toString = function () {
	'use strict';
	return "USPatentPeakReporter()";
};

if (Env.PeakReportersArray) {
	Env.PeakReportersArray.push(new USPatentPeakReporter());
}
